package com.mill.controller;

import java.util.List;
import java.util.Map;

import javax.annotation.Resource;

import org.apache.log4j.Logger;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.mill.model.Book;
import com.mill.service.BookService;

@RestController
@RequestMapping("book")
public class BookController {
	private static Logger logger = Logger.getLogger(BookController.class);
	
	@Resource
	private BookService bookSerivce;
	
	@GetMapping("all")
	public List<Book> findll() {
		return bookSerivce.findall();
	}
}
